﻿using Microsoft.AspNetCore.Hosting;
using NLog;
using NLog.Web;

namespace MingYuanYun.WebApi.Logging
{
    public static class NLogExtensions
    {
        public static IWebHostBuilder UseStructuredNLog(this IWebHostBuilder builder)
        {
            LogManager.LoadConfiguration("nlog.config");

            builder.UseNLog();

            return builder;
        }
    }
}
